package com.iotechn.unimall.app.api.service;

import com.dobbinsoft.fw.core.annotation.HttpMethod;
import com.dobbinsoft.fw.core.annotation.HttpOpenApi;
import com.dobbinsoft.fw.core.annotation.HttpParam;
import com.dobbinsoft.fw.core.annotation.HttpParamType;
import com.dobbinsoft.fw.core.annotation.param.NotNull;
import com.dobbinsoft.fw.core.exception.ServiceException;
import com.iotechn.unimall.data.domain.ServerDO;
import com.iotechn.unimall.data.vo.TreeVO;

import java.util.List;

@HttpOpenApi(group = "serve", description = "服务")
public interface ServeService {

    @HttpMethod(description = "服务树级")
    public List<TreeVO> tree() throws ServiceException;

    @HttpMethod(description = "服务详情")
    public ServerDO detail(
            @NotNull @HttpParam(name = "serverId", type = HttpParamType.COMMON, description = "服务id") Long serverId,
            @HttpParam(name = "userId", type = HttpParamType.USER_ID, description = "用户Id") Long userId) throws ServiceException;

}
